home *** CD-ROM | disk | FTP | other *** search
/ Amiga Tools 2 / Amiga Tools 2.iso / tools / packer / ha0999beta / md_funcs.txt < prev    next >
Text File  |  1995-03-09  |  3KB  |  98 lines

  1. HA MACHINE SPECIFIC FUNCTIONS (machine.c/machine.h)
  2.  
  3. void md_init(void) 
  4.     Set up machine specific signal handling etc. 
  5.  
  6. char *md_strcase(char *s)
  7.     Set case of string to internal format and return pointer to string.  
  8.  
  9. char *md_arcname(char *name_req) 
  10.     Construct archive name from requested name name_req and 
  11.     return pointer to it.
  12.  
  13. void md_gethdr(int len) 
  14.     Read len bytes of machine specific header information from arcfile.
  15.  
  16. void md_puthdr(void) 
  17.     Write machine specific header information to arcfile. 
  18.  
  19. int md_filetype(char *path,char *name)
  20.     Return file type (T_SKIP, T_DIR, T_REGULAR or T_SPECIAL) for 
  21.     specified file and make it current file. This function is 
  22.     responsible of skiping over archive file when packing. 
  23.  
  24. int md_newfile(void) 
  25.     Setup machine specific header information for curren file 
  26.     and return length of header.
  27.  
  28. int md_special(unsigned char **sdata)
  29.     Point sdata to any data to be saved for special file (if any), 
  30.     and return lenght of the data.
  31.  
  32. U32B md_curfilesize(void) 
  33.     Return file size for current file.
  34.  
  35. U32B md_curfiletime(void) 
  36.     Returns file time for current file
  37.  
  38. int md_mkspecial(char *ofname,unsigned sdlen,unsigned char *sdata)
  39.     Make special file ofname using current machine specific header 
  40.     and sdlen bytes of information in sdata. 
  41.     Return zero on failure nozero on success.
  42.  
  43. void md_setft(char *file,U32B time) 
  44.     Set filetime for file to time.
  45.  
  46. void md_setfattrs(char *file) 
  47.     Set attributes (from machine specific heador) of file 
  48.     if useattr is nonzero. 
  49.  
  50. U32B md_systime() 
  51.     get system time.
  52.  
  53. void md_listhdr(void) 
  54.     print feader for file attributes to stdout.
  55.  
  56. void md_listdat(void) 
  57.     print attribute information from machine specific header.
  58.  
  59. char *md_timestring(unsigned long t) 
  60.     Return pointer to string representin "unix time" t.
  61.  
  62. void md_truncfile(int fh, U32B len) 
  63.     Truncate file pointed by handle fh to length len.
  64.  
  65. char *md_tohapath(char *mdpath) 
  66.     Construct internal representation for path mdpath.
  67.  
  68. char *md_tomdpath(char *hapath) 
  69.     Construct machine representation for path hapath. 
  70.  
  71. char *md_strippath(char *mdfullpath) 
  72.     Return path part of mdfullpath.
  73.  
  74. char *md_stripname(char *mdfullpath) 
  75.     Return name part of mdfullpath. 
  76.  
  77. char *md_pconcat(int delim, char *head, char *tail) 
  78.     Construct path from head, tail. This function is supposed to malloc
  79.     space for path. other parts of HA call free with returned pointer !
  80.  
  81. int md_namecmp(char *pat, char *cmp) 
  82.     Return nonzero if pattern pat matches filename cmp using
  83.     wildcards in machine specific manner.
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.  
  98.